﻿using System;
using System.ComponentModel.DataAnnotations;
using System.Collections.Generic;
using WalkingTec.Mvvm.Core;
using AssetManageSystem.Model.OrgManage;

namespace AssetManageSystem.Model.AssetManage
{
    /// <summary>
    /// 资产维修
    /// </summary>
    public class AssetRepair : PersistPoco
    {
        [Display(Name = "单据编号")]
        [Required(ErrorMessage = "Validate.{0}required")]
        public string DocNumber { get; set; }

        [Display(Name = "待修资产")]
        [Required(ErrorMessage = "Validate.{0}required")]
        public Guid? RepairAssetId { get; set; }
        public AssetInfo RepairAsset { get; set; }

        [Display(Name = "报修人")]
        [Required(ErrorMessage = "Validate.{0}required")]
        public Guid? RepairmanId { get; set; }
        [Display(Name = "报修人")]
        public User Repairman { get; set; } 

        [Display(Name = "报修部门")]
        [Required(ErrorMessage = "Validate.{0}required")]
        public Guid? RepairDepId { get; set; }
        [Display(Name = "报修部门")]
        public Department RepairDep { get; set; }

        [Display(Name = "报修日期")]
        [Required(ErrorMessage = "Validate.{0}required")]
        public DateTime? OutDate { get; set; }

        [Display(Name = "维修单位")]
        [Required(ErrorMessage = "Validate.{0}required")]
        public string RepairUnit { get; set; }

        [Display(Name = "联系方式")]
        [Required(ErrorMessage = "Validate.{0}required")]
        public string Contacts { get; set; }

        [Display(Name = "维修内容")]
        [Required(ErrorMessage = "Validate.{0}required")]
        public string RepairInfo { get; set; }

    }
}
